import fetch from "@/api/fetch.js";

// 获取学生成绩列表
const getStudentExamList = (params) => {
  return fetch({
    url: "/student/exam/getStudentExamList",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 获取学生信息列表
const getStudentInformationList = (params) => {
  return fetch({
    url: "/student/information/list",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 获取学生信息列表
const resetPassword = (params) => {
  return fetch({
    url: "/student/information/resetPassword",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 获取学生信息详情
const getUserDetail = (params) => {
  return fetch({
    url: "/student/information/getUserDetail",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 修改学生信息
const userStudentUpdate = (params) => {
  return fetch({
    url: "/student/information/userStudentUpdate",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 获取自己所属学生考试筛选条件
const obtainMyOwnExamList = (params) => {
  return fetch({
    url: "/student/exam/obtainMyOwnExamList",
    method: "post",
    data: JSON.stringify(params),
  });
};


// 打分
const gradeStudents = (params) => {
  return fetch({
    url: "/student/exam/gradeStudents",
    method: "post",
    data: JSON.stringify(params),
  });
};

// 改分
const modifyGrades = (params) => {
  return fetch({
    url: "/student/exam/modifyGrades",
    method: "post",
    data: JSON.stringify(params),
  });
};





export default {
  getStudentExamList,
  getStudentInformationList,
  resetPassword,
  getUserDetail,
  userStudentUpdate,
  obtainMyOwnExamList,
  gradeStudents,
  modifyGrades
}
